package com.sc.nft.service;

import com.sc.nft.entity.*;
import com.sc.nft.entity.dto.ReceiveVerificationDTO;
import com.sc.nft.enums.MemberEquityTemplateeceiveCycleEnum;
import com.sc.nft.enums.ReceiveStatusEnum;

import java.util.Date;
import java.util.List;

/**
 * 用户领取优惠券记录服务接口
 *
 * @author liGen
 * @version 1.0
 * @date 2023/12/5 4:35 下午
 */
public interface ActivityCouponsUserService {

    /**
     * 用户领取优惠券活动
     *
     * @param activityCouponsId 活动优惠券ID
     * @param userInfo          用户
     * @return
     */
    void userReceive(Long activityCouponsId, UserInfo userInfo, Long memberId, Long memberEquityTemplateId);

    /**
     * 优惠券领取校验
     *
     * @param activityId 活动优惠券ID
     * @param startTime  活动开始时间
     * @param endTime    活动结束时间
     * @param userInfo
     * @return
     */
    ReceiveVerificationDTO receiveVerification(Long activityId, Date startTime, Date endTime, UserInfo userInfo, MallMemberEquity mallMemberEquity, MallMemberEquityTemplate mallMemberEquityTemplate);

    /**
     * 创建优惠券活动用户领取记录
     *
     * @param activityCoupons 优惠券活动
     * @param userInfo        用户
     * @param userCoupons     用户优惠券
     * @return
     */
    void create(ActivityCoupons activityCoupons, UserInfo userInfo, UserCoupons userCoupons, MallMemberEquity mallMemberEquity);

    /**
     * 获取用户该活动优惠券的领取记录
     *
     * @param userId    用户ID
     * @param couponsId 优惠券活动ID
     * @return
     */
    List<ActivityCouponsUser> getByUserId(Long userId, Long couponsId, Long mallMemberEquityId, Date startTime, Date endTime);
}
